// McDlgInput.cpp : implementation file
//

#include "stdafx.h"
#include "RouteNetClient.h"
#include "McDlgInput.h"

#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif

/////////////////////////////////////////////////////////////////////////////
// McDlgInput dialog


McDlgInput::McDlgInput(const string& prompt, CWnd* pParent /*=NULL*/)
	: CDialog(McDlgInput::IDD, pParent), prompt_(prompt)
{
	//{{AFX_DATA_INIT(McDlgInput)
		// NOTE: the ClassWizard will add member initialization here
	//}}AFX_DATA_INIT
}


void McDlgInput::DoDataExchange(CDataExchange* pDX)
{
	CDialog::DoDataExchange(pDX);
	//{{AFX_DATA_MAP(McDlgInput)
		// NOTE: the ClassWizard will add DDX and DDV calls here
	//}}AFX_DATA_MAP
}


BEGIN_MESSAGE_MAP(McDlgInput, CDialog)
	//{{AFX_MSG_MAP(McDlgInput)
	//}}AFX_MSG_MAP
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// McDlgInput message handlers

void McDlgInput::OnOK() 
{
	CString s;
	GetDlgItemText(IDC_EDIT_INFO, s);
	input_ = (LPCTSTR)s;
	CDialog::OnOK();
}

void McDlgInput::OnCancel() 
{
	CDialog::OnCancel();
}

BOOL McDlgInput::OnInitDialog() 
{
	CDialog::OnInitDialog();
	
	// TODO: Add extra initialization here
	SetWindowText(prompt_.c_str());
	return TRUE;  // return TRUE unless you set the focus to a control
	              // EXCEPTION: OCX Property Pages should return FALSE
}
